package com.ayg.vo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

@Data
@Accessors(chain = true)
@NoArgsConstructor
@AllArgsConstructor
public class UserResult {
    private Integer isValid; //是否可用
    private String msg;     //服务器提示信息
    private Object data;    //服务器返回的数据

    //账号注册异常返回参数列表
    public static UserResult StatusCode201(){
        return new UserResult(201, "该用户已存在！",null);
    }
    public static UserResult StatusCode202(){
        return new UserResult(202, "该账户已存在，请前往邮箱激活!",null);
    }
    public static UserResult StatusCode203(){
        return new UserResult(203, "账号异常，请联系爱忆港客服!",null);
    }
    public static UserResult StatusCode204(){
        return new UserResult(204, "注册成功，请前往邮箱进行账号激活!",null);
    }
    public static UserResult StatusCode205(){
        return new UserResult(205, "注册失败！",null);
    }
    public static UserResult StatusCode206(){
        return new UserResult(206, "该账户不存在或者未激活",null);
    }
    public static UserResult StatusCode207(){
        return new UserResult(207, "用户名或者密码错误",null);
    }
    //登录成功调用StatusCode208方法
    public static UserResult StatusCode208(Object data){
        return new UserResult(208, "登录成功",data);
    }
    public static UserResult StatusCode209(){
        return new UserResult(209, "链接已失效！请重新注册",null);
    }
    public static UserResult StatusCode210(){
        return new UserResult(210, "激活成功！",null);
    }
    public static UserResult StatusCode211(){
        return new UserResult(211, "激活失败！",null);
    }
    public static UserResult StatusCode212(){
        return new UserResult(212, "请前往邮箱进行重置确认！",null);
    }
    public static UserResult StatusCode213(){
        return new UserResult(213, "重置失败！",null);
    }
    public static UserResult StatusCode214(){
        return new UserResult(214, "重置成功！",null);
    }
}
